home *** CD-ROM | disk | FTP | other *** search
/ Sunday Savers: Singing Fun! / Sunday Savers: Singing Fun!.iso / mac / Xtras / Buddy API 1.6 / Buddy API Docs.swf / texts / 1540.txt < prev    next >
Encoding:
Text File  |  2004-08-31  |  3.9 KB  |  133 lines

  1. 132
  2. --- RECORDSEPARATOR ---
  3.  
  4. --- RECORDSEPARATOR ---
  5. CopyXFilesProgress
  6. --- RECORDSEPARATOR ---
  7.  
  8. --- RECORDSEPARATOR ---
  9. (continued)
  10. --- RECORDSEPARATOR ---
  11.  
  12. --- RECORDSEPARATOR ---
  13. Notes:
  14. --- RECORDSEPARATOR ---
  15.  
  16. --- RECORDSEPARATOR ---
  17. A return value of 7 (Dest file is newer than Source file) can only be returned when 
  18. --- RECORDSEPARATOR ---
  19. Overwrite is "IfNewer". The other return values can be returned for all Overwrite 
  20. --- RECORDSEPARATOR ---
  21. options. 
  22. --- RECORDSEPARATOR ---
  23. The "IfNewer" option operates as follows: if both files have internal version 
  24. --- RECORDSEPARATOR ---
  25. numbers, then these numbers are used for comparison, otherwise the dates of the 
  26. --- RECORDSEPARATOR ---
  27. two files are used for comparison. 
  28. --- RECORDSEPARATOR ---
  29. On
  30. --- RECORDSEPARATOR ---
  31.  Windows
  32. --- RECORDSEPARATOR ---
  33. , the FileSpec argument follows normal DOS wildcard rules. A * 
  34. --- RECORDSEPARATOR ---
  35. means match any character in the file name.  So *.* copies all files; *.bmp copies 
  36. --- RECORDSEPARATOR ---
  37. all files with a .bmp extension; T*.* copies all files starting with the letter T. 
  38. --- RECORDSEPARATOR ---
  39. On
  40. --- RECORDSEPARATOR ---
  41.  Macintosh
  42. --- RECORDSEPARATOR ---
  43. , The FileSpec is the four character type code eg "TEXT". Only one 
  44. --- RECORDSEPARATOR ---
  45. type can be specified. Use an empty string or "*.*" to match all files. 
  46. --- RECORDSEPARATOR ---
  47. Seven Flags are defined: 
  48. --- RECORDSEPARATOR ---
  49. CP_NOCANCEL 
  50. --- RECORDSEPARATOR ---
  51. --- RECORDSEPARATOR ---
  52. does not show the Cancel button. 
  53. --- RECORDSEPARATOR ---
  54. CP_NOFILENAME 
  55. --- RECORDSEPARATOR ---
  56. --- RECORDSEPARATOR ---
  57. does not display the file names while copying. 
  58. --- RECORDSEPARATOR ---
  59. CP_STOPONERROR 
  60. --- RECORDSEPARATOR ---
  61. --- RECORDSEPARATOR ---
  62. stop copying if an error occurs 
  63. --- RECORDSEPARATOR ---
  64. CP_NODIALOG 
  65. --- RECORDSEPARATOR ---
  66. --- RECORDSEPARATOR ---
  67. does not show the dialog box 
  68. --- RECORDSEPARATOR ---
  69. CP_CALLBACK 
  70. --- RECORDSEPARATOR ---
  71. 16 
  72. --- RECORDSEPARATOR ---
  73. enable the copy callback handler 
  74. --- RECORDSEPARATOR ---
  75. CP_ANIMATE 
  76. --- RECORDSEPARATOR ---
  77. 32 
  78. --- RECORDSEPARATOR ---
  79. shows system file copying animation (Windows only) 
  80. --- RECORDSEPARATOR ---
  81. CP_SIZEUPDATE 
  82. --- RECORDSEPARATOR ---
  83. 64 
  84. --- RECORDSEPARATOR ---
  85. updates 
  86. --- RECORDSEPARATOR ---
  87. the callback handler by size 
  88. --- RECORDSEPARATOR ---
  89. You can add any of these flags together to customize the dialog box. 
  90. --- RECORDSEPARATOR ---
  91. To implement the callback handler, use the CP_CALLBACK flag. Typically you 
  92. --- RECORDSEPARATOR ---
  93. would also use the CP_NODIALOG flag and implement your own dialog box. If you 
  94. --- RECORDSEPARATOR ---
  95. use this flag then you need to add a handler called 'baCopyProgressUpdate'. This 
  96. --- RECORDSEPARATOR ---
  97. handler needs to be a movie script. 
  98. --- RECORDSEPARATOR ---
  99. This handler will have two arguments passed into it - the percentage copied so far 
  100. --- RECORDSEPARATOR ---
  101. and the current file being copied. The handler will be called whenever the 
  102. --- RECORDSEPARATOR ---
  103. percentage copied has increased by one, or a new file is being copied. If you 
  104. --- RECORDSEPARATOR ---
  105. specify the CP_SIZEUPDATE, then your handler will be called whenever 
  106. --- RECORDSEPARATOR ---
  107. approximately 64k of data has been copied, rather than by percentage. 
  108. --- RECORDSEPARATOR ---
  109. To stop copying, you can return 1 in your handler; return 0 or no return to continue 
  110. --- RECORDSEPARATOR ---
  111. copying. An example handler is listed below - the update functions would be used 
  112. --- RECORDSEPARATOR ---
  113. to update your own progress dialog. 
  114. --- RECORDSEPARATOR ---
  115. on baCopyProgressUpdate percentage, filename 
  116. --- RECORDSEPARATOR ---
  117. updateProgressBar percentage 
  118. --- RECORDSEPARATOR ---
  119. updateStatus fileName 
  120. --- RECORDSEPARATOR ---
  121. if keyPressed( " " ) then -- if user presses space bar, stop copying 
  122. --- RECORDSEPARATOR ---
  123. return 1 
  124. --- RECORDSEPARATOR ---
  125. end if 
  126. --- RECORDSEPARATOR ---
  127. end 
  128. --- RECORDSEPARATOR ---
  129. The callback handler is only available on Director.